#pragma once

#include <opencv2/highgui.hpp>
#include <stdint.h>

struct DetectRect_t
{
    uint32_t x = 0;
    uint32_t y = 0;
    uint32_t w = 0;
    uint32_t h = 0;
};

struct DetectBBox_t
{
    std::vector<DetectRect_t> rects;
    uint32_t index = 0;
};
int init(const std::string& haarcascadePath);

int detect(cv::Mat frame, DetectBBox_t &bboxs, uint32_t index);